package com.lhkj.ct.meta.modules.questionnaire.model.entity;

import com.baomidou.mybatisplus.annotation.FieldFill;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableLogic;
import com.lhkj.ct.base.enums.DeleteStatus;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;

import java.io.Serializable;
import java.sql.Time;
import java.time.LocalDateTime;

/**
 * <p>
 * 问卷作答记录
 * </p>
 *
 * @author jobob
 * @since 2023-10-26
 */
@Data
@EqualsAndHashCode(callSuper = false)
@ApiModel(value="TblQnrResult对象", description="问卷作答记录")
public class TblQnrResult implements Serializable {

    private static final long serialVersionUID = 1L;

    @ApiModelProperty(value = "作答记录id")
    private String id;

    @ApiModelProperty(value = "分配记录id")
    private String allotId;

    @ApiModelProperty(value = "问卷id")
    private String qnrId;

    @ApiModelProperty(value = "档案id")
    private String patId;

    @ApiModelProperty(value = "姓名")
    private String patName;

    /**
     * 这里存的是字典值 1,2
     */
    @ApiModelProperty(value = "性别")
    private String patSex;

    @ApiModelProperty(value = "年龄")
    private Integer patAge;

    @ApiModelProperty(value = "作答结果json", notes = "用于回显作答结果")
    private String answerJson;

    @ApiModelProperty(value = "计时", hidden = true)
    private Time costTime;

    @ApiModelProperty(value = "是否匿名提交")
    private Boolean anonymous;

    @ApiModelProperty(value = "提交时间")
    private LocalDateTime submissionTime;

    @ApiModelProperty(value = "作答状态 0.作答中 1.已完成", hidden = true)
    private Integer status;

    @TableLogic
    @TableField(fill = FieldFill.INSERT)
    @ApiModelProperty(value = "是否删除 0.未删除 1.已删除")
    private DeleteStatus delFlag;

    @TableField(exist = false)
    @ApiModelProperty(value = "问卷名称")
    private String qnrName;

}
